{% extends 'layout.html' %}

{% block title %}编辑客户{% endblock %}

{% block content %}
<div class="container">
  <h2>编辑客户信息</h2>
  <form method="POST">
    <div class="form-group">
      <label>客户编号</label>
      <input type="text" class="form-control" name="customerID" value="{{ customer.customerID }}" disabled>
    </div>
    <div class="form-group">
      <label>姓名</label>
      <input type="text" class="form-control" name="customerName" value="{{ customer.customerName }}" required>
    </div>
    <div class="form-group">
      <label>身份证号</label>
      <input type="text" class="form-control" name="PID" value="{{ customer.PID }}" required>
    </div>
    <div class="form-group">
      <label>联系电话</label>
      <input type="text" class="form-control" name="telephone" value="{{ customer.telephone }}" required>
    </div>
    <div class="form-group">
      <label>地址</label>
      <input type="text" class="form-control" name="address" value="{{ customer.address }}" required>
    </div>
    <button type="submit" class="btn btn-primary">保存修改</button>
    <a href="{{ url_for('customers') }}" class="btn btn-secondary">取消</a>
  </form>
</div>
{% endblock %}
